home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Aminet 16
/
Aminet 16 (1996)(GTI - Schatztruhe)[!][Dec 1996].iso
/
Aminet
/
comm
/
term
/
term_source.lha
/
Extras
/
Source
/
gtlayout-source.lha
/
LTP_RenderArrow.c
< prev
next >
Wrap
C/C++ Source or Header
|
1996-03-18
|
654b
|
38 lines
/*
** GadTools layout toolkit
**
** Copyright © 1993-1996 by Olaf `Olsen' Barthel
** Freely distributable.
**
** :ts=4
*/
#ifndef _GTLAYOUT_GLOBAL_H
#include "gtlayout_global.h"
#endif
#ifdef DO_TAPEDECK_KIND
VOID
LTP_RenderArrow(struct RastPort *RPort,BOOL LeftDirection,LONG Left,LONG Top,LONG Width,LONG Height)
{
LONG i,Len,Start,Pos;
for(i = 0 ; i < Width ; i++)
{
Len = ((Height * (i + 1)) / Width) & ~1;
if(Len < Height)
Len++;
Start = Top + (Height - Len) / 2;
if(LeftDirection)
Pos = Left + i;
else
Pos = Left + Width - 1 - i;
LTP_DrawLine(RPort,Pos,Start,Pos,Start + Len - 1);
}
}
#endif /* DO_TAPEDECK_KIND */